//
//  PlayInView.h
//  playin
//
//  Created by playin on 2019/2/26.
//  Copyright © 2019年 playin. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>
#import <VideoToolbox/VideoToolbox.h>

NS_ASSUME_NONNULL_BEGIN

@protocol PlayInViewDelegate <NSObject>

- (void)onPlayInViewTouch:(NSData *)touchData;

@end

@interface PlayInView : UIView

@property (nonatomic, weak) id<PlayInViewDelegate> delegate;

- (instancetype)initWithFrame:(CGRect)frame
                  deviceWidth:(CGFloat)deviceWidth
                 deviceHeight:(CGFloat)deviceHeight
                  orientation:(int)orientation
                       osType:(int)osType;

- (void)displayPixelBuffer:(CVPixelBufferRef)pixelBuffer;
- (void)displayPreviousPixelBuffer:(CVPixelBufferRef)pixelBuffer;
@end

NS_ASSUME_NONNULL_END
